﻿using System;
using System.Collections.Generic;
using System.Windows.Forms;
using BakalarskaPraca.Generation.Data;
using BakalarskaPraca.Generation.Tasks;
using BakalarskaPraca.Generation.Tasks.Abstract;
using BakalarskaPraca.Interfaces;

namespace BakalarskaPraca.Forms.GenerationSettingsForms
{
    public partial class HumidityConstantValueSettingsForm : HumidityConstantValueSettingsFormBase
    {
        public HumidityConstantValueSettingsForm()
        {
            InitializeComponent();
        }

        public override bool ShowSettings(HumidityConstantHumidity generationProcess)
        {
            this.numericTextBox1.IntValue = generationProcess.HumidityValue;
            if (this.ShowDialog() == DialogResult.OK)
            {
                generationProcess.HumidityValue = this.numericTextBox1.IntValue;
                return true;
            }
            return false;
        }

        public override GenerationProcess GetNewGenerationProcess(List<HumidityPolygon> polygons, ModelData modelData)
        {
            return new HumidityConstantHumidity(polygons, modelData);
        }
    }

    public class HumidityConstantValueSettingsFormBase : GenerationSettingsFormBase<HumidityConstantHumidity> { }

    
}
